Net (command)
   HOME

TheInfoList



OR:

In
computing Computing is any goal-oriented activity requiring, benefiting from, or creating computing machinery. It includes the study and experimentation of algorithmic processes, and development of both hardware and software. Computing has scientific, ...
, net is a
command Command may refer to: Computing * Command (computing), a statement in a computer language * COMMAND.COM, the default operating system shell and command-line interpreter for DOS * Command key, a modifier key on Apple Macintosh computer keyboards * ...
in IBM
OS/2 OS/2 (Operating System/2) is a series of computer operating systems, initially created by Microsoft and IBM under the leadership of IBM software designer Ed Iacobucci. As a result of a feud between the two companies over how to position OS/2 r ...
(including
eComStation eComStation or eCS is an operating system based on OS/2 Warp for the 32-bit x86 architecture. It was originally developed by Serenity Systems and Mensys BV under license from IBM. It includes additional applications, and support for new hard ...
and ArcaOS), Microsoft Windows and ReactOS used to manage and configure the operating system from the
command-line A command-line interpreter or command-line processor uses a command-line interface (CLI) to receive commands from a user in the form of lines of text. This provides a means of setting parameters for the environment, invoking executables and pro ...
. It is also part of the IBM PC Network Program for
DOS DOS is shorthand for the MS-DOS and IBM PC DOS family of operating systems. DOS may also refer to: Computing * Data over signalling (DoS), multiplexing data onto a signalling channel * Denial-of-service attack (DoS), an attack on a communicat ...
.IBM PC Network Program 1.0 Users Guide
/ref>


Overview

The command is primarily used to manage network resources.
/ref> It is an external command implemented as net.exe.
/ref> When used in a
batch file Batch may refer to: Food and drink * Batch (alcohol), an alcoholic fruit beverage * Batch loaf, a type of bread popular in Ireland * A dialect term for a bread roll used in North Warwickshire, Nuneaton and Coventry, as well as on the Wirra ...
, the /Y or /N switches can be used to unconditionally answer Yes or No to questions returned by the command. The net command has several sub-commands that can differ from one implementation or operating system version to another. On
Windows CE .NET 4.2 Windows Embedded Compact, formerly Windows Embedded CE, Windows Powered and Windows CE, is an operating system subfamily developed by Microsoft as part of its Windows Embedded family of products. Unlike Windows Embedded Standard, which is base ...
, Windows CE 5.0 and Windows Embedded CE 6.0, it is available as an external command stored in . This version only supports the ''use'' and ''view'' sub-commands.


Example

The net use command has several
network Network, networking and networked may refer to: Science and technology * Network theory, the study of graphs as a representation of relations between discrete objects * Network science, an academic field that studies complex networks Mathematics ...
-related functions.


Connecting network drive and printer

net use can control mounting (" mapping" in Microsoft terminology) drive shares and connecting shared printers in a network environment. This command makes use of the SMB (server message block) and the
NetBIOS NetBIOS () is an acronym for Network Basic Input/Output System. It provides services related to the session layer of the OSI model allowing applications on separate computers to communicate over a local area network. As strictly an API, Ne ...
protocol on port 139 or 445. The basic Windows XP configuration enables this functionality by default. Thus users can connect to and disconnect from shared resources such as computers, printers and drives. net use can display a list of network-connection information on shared resources.


Null session connections

net use also connects to the IPC$ (interprocess communication share). This is the so-called null session connection, which allows unauthenticated users. The basic syntax for connecting anonymously is: net use \\IP address\IPC$ "" /u:"" For example, typing at the command prompt: net use \\192.168.1.101\IPC$ "" /u:"" attempts to connect to the share IPC$ of the network 192.168.1.101 as an anonymous user with blank password. If successfully connected to the target machine, a lot of information can be gathered such as shares, users, groups, registry keys and more. This would provide a hacker with a lot of information about a remote user. This has changed in Windows NT 4.0 SP6 already. In Windows 2000 "null session connections" could have been enabled after changes of the system-configuration.


Similar commands in other OSes

*
Novell NetWare NetWare is a discontinued computer network operating system developed by Novell, Inc. It initially used cooperative multitasking to run various services on a personal computer, using the IPX network protocol. The original NetWare product in ...
**map for mapping
volumes Volume is a measure of occupied three-dimensional space. It is often quantified numerically using SI derived units (such as the cubic metre and litre) or by various imperial or US customary units (such as the gallon, quart, cubic inch). The defi ...
(
network drive In computing, a file server (or fileserver) is a computer attached to a network that provides a location for shared disk access, i.e. storage of computer files (such as text, image, sound, video) that can be accessed by the workstations that are ab ...
s) to
drive letter In computer data storage, drive letter assignment is the process of assigning alphabetical identifiers to volumes. Unlike the concept of UNIX mount points, where volumes are named and located arbitrarily in a single hierarchical namespace, driv ...
s **capture for capturing
print queue In computing, a print job is a file or set of files that has been submitted to be printed with a printer. Jobs are typically identified by a unique number, and are assigned to a particular destination, usually a printer. Jobs can also have optio ...
s to LPT ports


See also

*
List of DOS commands This article presents a list of commands used by DOS operating systems, especially as used on x86-based IBM PC compatibles (PCs). Other DOS operating systems are not part of the scope of this list. In DOS, many standard system commands were pro ...
*
MS-Net MS-Net, sometimes stylized as MS-NET, was an early network operating system sold by Microsoft during the earliest days of local area networking (LANs). Overview MS-Net was not a complete networking system of its own; Microsoft licensed it to vend ...


References


Further reading

* * *


External links


Microsoft TechNet
* {{Windows commands Microcomputer software OS/2 commands Windows administration Windows communication and services